import FieldProps, {type IFieldProps} from '../../basic/FieldProps'

export interface IInputProps extends IFieldProps{
  type: 'text'|'textarea'|'password',
  rows: number,
}
export default class InputProps extends FieldProps implements IInputProps{
  public type = 'text' as any;
  public rows = 1;

  constructor(props?:IInputProps) {
    super({
      widgetLabel: "输入框",
      widgetType: "INPUT",
      ...(props||{})
    });
    if(props){
      this.type = props.type || this.type;
      this.rows = props.rows || this.rows;
    }
  }
}